package com.yuyu.demo.demo_springboot.config;

import com.fasterxml.jackson.databind.ObjectMapper;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 初始化配置，用来配置一些通用的实例化Bean
 *
 * @author yuyu <yu.yu@chinaott.net>
 * @date 2017-12-23
 */

@Configuration
public class InitConfig {

    /**
     * Spring boot 自带的 jackson工具
     */
    @Bean
    public ObjectMapper ObjectMapper(){
        ObjectMapper objectMapper=new ObjectMapper();
        return objectMapper;
    }
}
